package com.example.travelservlet.user.service;

import com.example.travelservlet.entity.Label;
import com.example.travelservlet.entity.User;
import org.springframework.data.domain.Page;
import org.springframework.data.domain.Pageable;

import java.util.List;

/**
 * @author dell
 */
public interface UserService {
    /**
     *
     * @param loginName 登录名
     * @return 用户对象
     */
    User findUserByLoginName(String loginName);

    /**
     *
     * @param user 用户对象
     * @return 用户对象
     */
    User createUser(User user);

    /**
     *
     * @param
     */
    void deleteByLoginName(String loginName);

    /**
     *
     * @param user 用户对象
     * @return 用户对象
     */
    User updateUser(User user);

    /**
     *
     * @param
     * @return
     */
    List<User> findUser();

    List<User> findUserInfo(User user);

    Page findAllUser(User user, Pageable pageable);

    List<User> findAllUsers();
    Page findAllUsers1(Pageable pageable);


    List<User> findUsersByKey(String key);

    List<User> findResearch(String str);

    Page findUsersByKey1(String key, Pageable pageable);
}
